package com.haois.ws.web.module.navigate.service;

import com.haois.ws.web.module.navigate.dao.mapper.WebSiteMapper;
import com.haois.ws.web.module.navigate.daomain.WebSite;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

/**
 * Created by RuiHaoZ on 2018/3/11 11:57
 */
@Service
public class WebSiteService {
    @Autowired
    private WebSiteMapper webSiteMapper;

    public List<WebSite> getAllApp() {
        return webSiteMapper.getAllApp();
    }

    public WebSite getByAppId(String appId) {
        return webSiteMapper.getByAppId(appId);
    }

    public void addApp(WebSite app) {
        webSiteMapper.addApp(app);
    }

    public List<WebSite> getByAccountAndWebName(String account, String webName) {
        return webSiteMapper.getByAccountAndWebName(account, webName);
    }

    public List<WebSite> getByAccount(String account) {
        return webSiteMapper.getAppByAccount(account);
    }
}
